package com.itheima.dao;

import com.itheima.pojo.Exercise;
import com.itheima.pojo.Repository;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Select;

import java.util.List;

public interface RepositoryDao {
    @Insert("insert into t_repository values(null,#{title},#{keyWord},#{loreType},#{loreContent},#{isDelete},#{remark},#{chronicDisease})")
    void add(Repository repository);
    @Insert("insert into t_exercise values(null,#{name},#{runtime},#{ecount},#{kmCon})")
    void addExercise(Exercise exercise);
     @Select("select title,keyWord,loreType,loreContent from t_repository limit 0,10")
    List<Repository> find();
}
